﻿using MovingChameLibrary.Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;

namespace MovingChame.WindowsStoreApp.CustomControl
{
    public class TourPageDataSelector : DataTemplateSelector
    {
        public DataTemplate TourOverviewTemplate { get; set; }
        public DataTemplate TourTimelineTemplate { get; set; }
        public DataTemplate TourPhotoTemplate { get; set; }

        protected override DataTemplate SelectTemplateCore(object item, DependencyObject container)
        {
            if (item is Tour)
                return TourOverviewTemplate;
            if (item is Schedule)
                return TourTimelineTemplate;

            return base.SelectTemplateCore(item, container);
        }
    }
}
